﻿if exists (select * from dbo.sysobjects where id = 
object_id(N'[dbo].[sp_CatalogReport]') 
and OBJECTPROPERTY(id, N'IsProcedure') = 1)
drop procedure [dbo].[sp_CatalogReport]
GO

SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

CREATE Procedure [dbo].[sp_CatalogReport]
As
Set NoCount On

select Category.ID as CategoryId, 
       Category.Name as CategoryName,
       Category.Description,
       Category.Picture,
       Product.ID as ProductId,
       Product.Name as ProductName,
       Product.QuantityPerUnit,
       Product.UnitPrice
from Category, Product
where Category.ID = Product.CategoryId
GO
        


